define(['template/mobile/edit','qrcode','wx','wx.tpl','wx.ajax'],function(tpl,qrcode,wx){
	
	var getUrl = frontWebUrl+'/mobile/site/show?id=';

	function init($body,id){
		$('#Js-particles').hide();
		$('#Js-publish-bg').css('height',$('#Js-publish-bg').parent()[0].scrollHeight).show();
		$body.empty().append(wx.tpl(tpl.publish,{url:getUrl+id}));
		var qrcode = new QRCode($('#Js-qrcode')[0], {
            width : 300,//设置宽高
            height : 300
        });
        qrcode.makeCode(getUrl+id);
	}

	return init;
});